#ifndef _DSWASP_H
#define _DSWASP_H

#include "base.h"
#ifdef __cplusplus
extern  "C" {
#endif

#ifndef WEBS
#define WEBS
#endif

#ifndef UEMF
#define UEMF
#endif

#ifndef OS
#define OS LINUX
#endif

#ifndef LINUX
#define LINUX
#endif

#include	<webs/uemf.h>
#include	<webs/wsIntrn.h>

#ifdef __cplusplus
}
#endif

class CDswasp
{
public:
	CDswasp();
	virtual ~CDswasp();
public:
	static int aspGetMaxChannles(int eid, webs_t wp, int argc, char_t **argv);
	
	static int aspGetPagLink(int eid, webs_t wp, int argc, char_t **argv);
	static void formSetPagLink(webs_t wp, char_t *path, char_t *query);

	static int aspGetNetWire(int eid, webs_t wp, int argc, char_t **argv);
	static void formSetNetWire(webs_t wp, char_t *path, char_t *query);

	static int aspGetNetPppoe(int eid, webs_t wp, int argc, char_t **argv);
	static void formSetNetPppoe(webs_t wp, char_t *path, char_t *query);

	static int aspGetVideo(int eid, webs_t wp, int argc, char_t **argv);
	static void formSetVideo(webs_t wp, char_t *path, char_t *query);
	static int aspGetVideoParam(int eid, webs_t wp, int argc, char_t **argv);
	static void formSetVideoParam(webs_t wp, char_t *path, char_t *query);
	static void formChangeVideo(webs_t wp, char_t *path, char_t *query);
	static void formChangeVideoParam(webs_t wp, char_t *path, char_t *query);
	static int aspGetAudio(int eid, webs_t wp, int argc, char_t **argv);
	static void formSetAudio(webs_t wp, char_t *path, char_t *query);

	static int aspGetAlarmTrig(int eid, webs_t wp, int argc, char_t **argv);
	static void formSetAlarmTrigType(webs_t wp, char_t *path, char_t *query);
	static void formSetAlarmTrig(webs_t wp, char_t *path, char_t *query);
	static int aspGetRfDevLearn(int eid, webs_t wp, int argc, char_t **argv);
	static void formSetRfDevLearnStatus(webs_t wp, char_t *path, char_t *query);
	static void formSetRfDevLearn(webs_t wp, char_t *path, char_t *query);
	static int aspGetAuto(int eid, webs_t wp, int argc, char_t **argv);
	static void formSetAuto(webs_t wp, char_t *path, char_t *query);

	static int aspGetTelBoard(int eid, webs_t wp, int argc, char_t **argv);
	static void formSetTelBoard(webs_t wp, char_t *path, char_t *query);

	static int aspGetSoundLight(int eid, webs_t wp, int argc, char_t **argv);
	static void formSetSoundLight(webs_t wp, char_t *path, char_t *query);

	static int aspGetDevLocate(int eid, webs_t wp, int argc, char_t **argv);
	static void formSetDevLocate(webs_t wp, char_t *path, char_t *query);

	static void formReboot(webs_t wp, char_t *path, char_t *query);

	static int aspGetTime(int eid, webs_t wp, int argc, char_t **argv);
	static void formSetTime(webs_t wp, char_t *path, char_t *query);

	static void formDefaultCfg(webs_t wp, char_t *path, char_t *query);

	static int aspGetSubDev(int eid, webs_t wp, int argc, char_t **argv);
	static void formSetSubDev(webs_t wp, char_t *path, char_t *query);

	static int aspGetHdAttr(int eid, webs_t wp, int argc, char_t **argv);
	static int aspGetHdStatus(int eid, webs_t wp, int argc, char_t **argv);
	static void formSetHdAttr(webs_t wp, char_t *path, char_t *query);
	static void cbOnNotifyFormat(int nPercent, ENM_HD_STATUS nStatus);

	static int aspGetDswVer(int eid, webs_t wp, int argc, char_t **argv);

	static void formUpgrade(webs_t wp, char_t *path, char_t *query);

	static void cbUpgrade(EN_UPGRADE_STEP nstep, double dpercent, void* pParam, void* pCaller);

	static int aspGetExtCams(int eid, webs_t wp, int argc, char_t **argv);
	static void formSetExtCams(webs_t wp, char_t *path, char_t *query);
	static void formSetExtCamsDescover(webs_t wp, char_t *path, char_t *query);

	static void formSetExtCamsDescover_vh(webs_t wp, char_t *path, char_t *query);

	static int aspGetLocalVideoPort(int eid, webs_t wp, int argc, char_t **argv);
	static void formSetPreSet(webs_t wp, char_t *path, char_t *query);

	static bool CheckValidKeyCode(char* pDevId, char* pKeyCode);

	static int aspGetPTZAddrBtl(int eid, webs_t wp, int argc, char_t **argv);
	static void formSetPTZAddrBtl(webs_t wp, char_t *path, char_t *query);
};

#endif

